	<div class="page-header users-header">
	  <h2>
		Duyệt hồ sơ PG - PB - MODEL
		 <?/*<a href="<?php echo site_url("admin").'/'.$this->uri->segment(2); ?>/add" class="btn btn-success">Add a new</a>*/?>
	  </h2>
	</div>
	<?php
		$ho_ten = array('name'=>'ho_ten','value'=>isset($ho_ten)?$ho_ten:set_value('ho_ten'),'class'=>'form-control');
		$email = array('name'=>'email','value'=>isset($email)?$email:set_value('email'),'class'=>'form-control', 'type'=>'email');
		$t_thai = array('-1'=>'Tất cả',0=>'Chờ duyệt',1=>'Đã duyệt',2=>'Không duyệt');
	?>
	<div class="row">
		<div class="span12 columns">
			<div class="well">
				<form style="margin-bottom:0;overflow:hidden;" class="form-inline" role="form" action="<?=base_url('admin/duyethosocanhan')?>" method="post">
					<div class="span3">
						<label>Họ tên:</label>
						<?=form_input($ho_ten)?>
					</div>
					<div class="span3">
						<label>Enail:</label>
						<?=form_input($email)?>
					</div>
					<div class="span3">
						<label>Trạng thái:</label>
						<?=form_dropdown('trang_thai',$t_thai, isset($trang_thai)?$trang_thai:set_value('trang_thai'),'')?>
					</div>
					<div class="span2">
						<input type="submit" class="btn btn-default form-control" value="Lọc"/>
					</div>
				</form>
			</div>
			<form method="post" action="<?=base_url('admin/duyethosocanhan/update')?>">
				<div style="margin-bottom:10px;">
					<?php if($updated = $this->session->flashdata('updated')):?>
					<div class="alert alert-info"><strong><?=$updated?></strong></div>
					<?php endif;?>
					<?php if($danger = $this->session->flashdata('danger')):?>
					<div class="alert alert-danger"><strong><?=$danger?></strong></div>
					<?php endif;?>
					<?php $status	=	array(0=>'Chờ duyệt',1=>'Duyệt',2=>'Không duyệt');?>
				</div>
				<div style="text-align:right">
					<strong>Trạng thái: </strong>
					<?=form_dropdown('status',$status,0,'style="width:120px;"')?>
					<input type="submit" class="btn btn-success" value="Cập nhật"/>
				</div>			
				<table id="" class="table table-striped table-bordered table-condensed ">
					<thead>
					  <tr>
						<th style="text-align:center" width="20px;">
							<input type="checkbox" onchange="check_all(this,event);"/>
						</th>
						<th class="header" width="25px;">STT</th>
						<th class="green header" width="50px;">Mã số</th>
						<th class="green header" >Họ tên</th>
						<th class="red header" width="230px;">Email</th>
						<th class="red header" width="110px;">Ngày cập nhật</th>
						<th class="red header" width="75px;">Trạng thái</th>
						<th class="red header" width="50px;">&nbsp;</th>
					  </tr>
					</thead>
					<tbody>
					<?php $i = 1;						
						foreach($hoso as $obj):?>
						<tr>
							<td style="text-align:center" onclick="row_click(this,event);">
								<input type="checkbox" name="hoso[]" value="<?=$obj->id?>"/>
							</td>							
							<td style="text-align:right" onclick="row_click(this,event);"><?php echo $stt++;?></td>
							<?/*<td>
								<img class="img-thumbnail" src="/assets/timthumb.php?w=80&h=80&src=<?=base_url('uploads/images/full/'.$obj->avatar)?>" alt="Hồ sơ PG: Hồ Minh Khuyến">
							</td>*/?>
							<td>
								<?=$obj->code?>
							</td>
							<td onclick="row_click(this,event);"><?=$obj->ho_ten?></td>
							<td onclick="row_click(this,event);"><?=$obj->email;?></td>
							<td onclick="row_click(this,event);"><?=date('d/m/Y H:i', strtotime($obj->ngay_cap_nhat))?></td>
							<td onclick="row_click(this,event);"><?=$status[$obj->trang_thai]?></td>
							<td>
								<a href="<?=base_url('admin/duyethosocanhan/canhan/'.$obj->id);?>" class="btn btn-info">Xem</a>
							</td>
						</tr>
					<?php endforeach;?>      
					</tbody>
				</table>
			</form>
		 <?php echo '<div class="pagination">'.$this->pagination->create_links().'</div>'; ?>
	</div>
